package org.dromara.answer.domain.bo;

import lombok.*;
import org.dromara.answer.domain.AiOptions;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import jakarta.validation.constraints.*;

/**
 * 选项业务对象 ai_options
 *
 * @author Lion Li
 * @date 2025-04-09
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = AiOptions.class, reverseConvertGenerate = false)
@AllArgsConstructor
@NoArgsConstructor
@Builder
public class AiOptionsBo extends BaseEntity {

    /**
     * 选项ID，主键
     */
    @NotNull(message = "选项ID，主键不能为空", groups = { EditGroup.class })
    private Long optionId;

    /**
     * 关联的题目ID
     */
    @NotNull(message = "关联的题目ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long questionId;

    /**
     * 选项内容
     */
    @NotBlank(message = "选项内容不能为空", groups = { AddGroup.class, EditGroup.class })
    private String optionContent;

    /**
     * 选项顺序
     */
    @NotNull(message = "选项顺序不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long optionOrder;

    /**
     * 标签
     */
    private String label;
}
